#pragma once


using namespace std;
namespace zjw
{     template<class  Iterator,class Ref,class Ptr>
	struct Reverselterator
	{
		typedef Reverselterator<Iterator, Ref, Ptr>Self;
		Iterator _it;
		Reverselterator(Iterator it)
			:_it(it)
		{}
		Ref operator*()
		{
			Iterator tmp = _it;
			return *(--tmp);
		
		}
		Ptr operator->()
		{
			return & (operator*());
		
		}
		Self& operator++()
		{
			--_it;
			return *this;
		
		}
		Self& operator--()
		{
			++_it;
			return *this;

		}
		bool operator!=(const Self& s)
		{
		    return _it != s._it;
		}
	};
}
